package com.wjw.interfacesegregation.segregation02;

import com.wjw.interfacesegregation.segregation02.service.impl.Chicken;

/**
 * TODO: 描述
 *
 * @author ikaros
 * @date 2024/7/7 22:58
 * @see <a href="ikaros@qq.com">mailTo: ikaros@qq.com</a>
 */
public class Kun02 {

    public static void main(String[] args) {
        Kun02 kun02 = new Kun02();
        Chicken chicken = new Chicken();
        kun02.dependSing(chicken);
        kun02.dependBall(chicken);
        kun02.depenMusic(chicken);
    }

    public void dependSing(Chicken chicken) {
        System.out.println("Kun02依赖于sing方法");
        chicken.sing();
    }

    public void dependBall(Chicken chicken) {
        System.out.println("Kun02依赖于basketball方法");
        chicken.basketball();
    }

    public void depenMusic(Chicken chicken) {
        System.out.println("Kun02依赖于music方法");
        chicken.music();
    }
}
